<% if p["social_media_description"] %>
  <meta name="description" content="<%= p["meta_description"]["value"] %>" />
<% end %>

<link rel="canonical" href="<%= url %>" />
<meta http-equiv="content-language" content="<%= locale %>" />
<meta name="identifier-url" content="<%= url %>" />

<% if p["publisher"] %>
  <meta name="publisher" content="<%= p["publisher"]["value"] %>" />
<% end %>

<% if p["copyright"] %>
  <meta name="copyright" content="<%= p["copyright"]["value"] %>" />
<% end %>

<meta property="og:locale" content="<%= cc[:facebook_locale] %>" />
<meta property="og:type" content="website" />

<% if p["facebook_site_name"] %>
  <meta property="og:site_name" content="<%= p["facebook_site_name"]["value"] %>" />
<% end %>

<meta property="og:url" content="<%= url %>" />
<meta property="og:title" content="<%= p["social_media_title"]["value"] %>" />

<% if p["social_media_description"] %>
  <meta property="og:description" content="<%= p["social_media_description"]["value"] %>" />
<% end %>

<% if p["social_media_logo"]["value"] %>
  <meta property="og:image" content="<%= p["social_media_logo"]["value"] %>" />
  <meta property="og:image:width" content="1200" />
  <meta property="og:image:height" content="600" />
<% elsif p["facebook_image"] %>
  <meta property="og:image" content="<%= p["facebook_image"]["src"] %>" />

  <% if p["facebook_image"]["content_type"] %>
    <meta property="og:image:type" content="<%= p["facebook_image"]["content_type"] %>" />
  <% end %>

  <meta property="og:image:width" content="2000" />
  <meta property="og:image:height" content="1328" />
<% end %>

<% if cc[:facebook_connect_id] %>
  <meta property="fb:app_id" content="<%= cc[:facebook_connect_id] %>" />
<% end %>

<% if cc[:social_image] %>
  <meta name="twitter:card" content="summary_large_image" />
<% else %>
  <meta name="twitter:card" content="summary" />
<% end %>

<% if p["twitter_handle"] && p["twitter_handle"]["value"] %>
  <meta name="twitter:site" content="@<%= p["twitter_handle"]["value"] %>" />
  <meta name="twitter:creator" content="@<%= p["twitter_handle"]["value"] %>" />
<% end %>

<% if p["social_media_logo"]["value"] %>
  <meta name="twitter:image" content="<%= p["social_media_logo"]["value"] %>" />
<% elsif p["twitter_image"] %>
  <meta name="twitter:image" content="<%= p["twitter_image"]["src"] %>" />
<% end %>

<meta name="twitter:title" content="<%= p["social_media_title"]["value"] %>" />
<meta name="twitter:url" content="<%= url %>" />

<% if p["social_media_description"] %>
  <meta name="twitter:description" content="<%= p["social_media_description"]["value"] %>" />
<% end %>

<% if p["google_site_verification"] %>
  <meta name="google-site-verification" content="<%= p["google_site_verification"]["value"] %>" />
<% end %>
